home *** CD-ROM | disk | FTP | other *** search
/ Aminet 45 / Aminet 45 (2001)(GTI - Schatztruhe)[!][Oct 2001].iso / Aminet / gfx / x11 / x3270_3_2_16.lha / amiga_src / CmplxMenu.h < prev    next >
C/C++ Source or Header  |  2007-03-01  |  6KB  |  162 lines

  1. /*
  2.  * (from) $XConsortium: SimpleMenu.h,v 1.20 91/02/17 13:18:55 rws Exp $
  3.  *
  4.  * Modifications Copyright 1995, 1999 by Paul Mattes.
  5.  *  Permission to use, copy, modify, and distribute this software and its
  6.  *  documentation for any purpose and without fee is hereby granted,
  7.  *  provided that the above copyright notice appear in all copies and that
  8.  *  both that copyright notice and this permission notice appear in
  9.  *  supporting documentation.
  10.  *
  11.  * Copyright 1989 Massachusetts Institute of Technology
  12.  *
  13.  * Permission to use, copy, modify, distribute, and sell this software and its
  14.  * documentation for any purpose is hereby granted without fee, provided that
  15.  * the above copyright notice appear in all copies and that both that
  16.  * copyright notice and this permission notice appear in supporting
  17.  * documentation, and that the name of M.I.T. not be used in advertising or
  18.  * publicity pertaining to distribution of the software without specific,
  19.  * written prior permission.  M.I.T. makes no representations about the
  20.  * suitability of this software for any purpose.  It is provided "as is"
  21.  * without express or implied warranty.
  22.  *
  23.  * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
  24.  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T.
  25.  * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  26.  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
  27.  * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN 
  28.  * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  29.  *
  30.  * Author:  Chris D. Peterson, MIT X Consortium
  31.  */
  32.  
  33. /*
  34.  * ComplexMenu.h - Public Header file for ComplexMenu widget.
  35.  * (from) SimpleMenu.h - Public Header file for SimpleMenu widget.
  36.  *
  37.  * This is the public header file for the Athena ComplexMenu widget.
  38.  * It is intended to provide one pane pulldown and popup menus within
  39.  * the framework of the X Toolkit.  As the name implies it is a first and
  40.  * by no means complete implementation of menu code. It does not attempt to
  41.  * fill the needs of all applications, but does allow a resource oriented
  42.  * interface to menus.
  43.  *
  44.  * Date:    April 3, 1989
  45.  *
  46.  * By:      Chris D. Peterson
  47.  *          MIT X Consortium 
  48.  *          kit@expo.lcs.mit.edu
  49.  */
  50.  
  51. #ifndef _ComplexMenu_h
  52. #define _ComplexMenu_h
  53.  
  54. #include <X11/Shell.h>
  55. #include <X11/Xmu/Converters.h>
  56. #include <X11/Xfuncproto.h>
  57.  
  58. /****************************************************************
  59.  *
  60.  * ComplexMenu widget
  61.  *
  62.  ****************************************************************/
  63.  
  64. /* ComplexMenu Resources:
  65.  
  66.  Name             Class        RepType        Default Value
  67.  ----             -----        -------        -------------
  68.  background         Background        Pixel        XtDefaultBackground
  69.  backgroundPixmap    BackgroundPixmap    Pixmap          None
  70.  borderColor         BorderColor    Pixel        XtDefaultForeground
  71.  borderPixmap         BorderPixmap    Pixmap        None
  72.  borderWidth         BorderWidth    Dimension    1
  73.  bottomMargin        VerticalMargins    Dimension       VerticalSpace
  74.  columnWidth         ColumnWidth        Dimension       Width of widest text
  75.  cursor              Cursor             Cursor          None
  76.  destroyCallback     Callback        Pointer        NULL
  77.  height             Height        Dimension    0
  78.  label               Label              String          NULL (No label)
  79.  labelClass          LabelClass         Pointer         cmeBSBObjectClass
  80.  mappedWhenManaged   MappedWhenManaged    Boolean        True
  81.  rowHeight           RowHeight          Dimension       Height of Font
  82.  sensitive         Sensitive        Boolean        True
  83.  topMargin           VerticalMargins    Dimension       VerticalSpace
  84.  width             Width        Dimension    0
  85.  x             Position        Position    0n
  86.  y             Position        Position    0
  87.  
  88. */
  89.  
  90. typedef struct _ComplexMenuClassRec*    ComplexMenuWidgetClass;
  91. typedef struct _ComplexMenuRec*        ComplexMenuWidget;
  92.  
  93. extern WidgetClass complexMenuWidgetClass;
  94.  
  95. #define XtNcursor "cursor"
  96. #define XtNbottomMargin "bottomMargin"
  97. #define XtNcolumnWidth "columnWidth"
  98. #define XtNlabelClass "labelClass"
  99. #define XtNmenuOnScreen "menuOnScreen"
  100. #define XtNpopupOnEntry "popupOnEntry"
  101. #define XtNrowHeight "rowHeight"
  102. #define XtNtopMargin "topMargin"
  103. #define XtNcMparent "cMparent"
  104. #define XtNcMdefer "cMdefer"
  105.  
  106. #define XtCColumnWidth "ColumnWidth"
  107. #define XtCLabelClass "LabelClass"
  108. #define XtCMenuOnScreen "MenuOnScreen"
  109. #define XtCPopupOnEntry "PopupOnEntry"
  110. #define XtCRowHeight "RowHeight"
  111. #define XtCVerticalMargins "VerticalMargins"
  112. #define XtCCMparent "CMparent"
  113. #define XtCCMdefer "CMdefer"
  114.  
  115. /************************************************************
  116.  *
  117.  * Public Functions.
  118.  *
  119.  ************************************************************/
  120.  
  121. _XFUNCPROTOBEGIN
  122.  
  123. /*    Function Name: XawComplexMenuAddGlobalActions
  124.  *    Description: adds the global actions to the complex menu widget.
  125.  *    Arguments: app_con - the appcontext.
  126.  *    Returns: none.
  127.  */
  128.  
  129. extern void XawComplexMenuAddGlobalActions(
  130. #if NeedFunctionPrototypes
  131.     XtAppContext    /* app_con */
  132. #endif
  133. );
  134.  
  135. /*    Function Name: XawComplexMenuGetActiveEntry
  136.  *    Description: Gets the currently active (set) entry.
  137.  *    Arguments: w - the smw widget.
  138.  *    Returns: the currently set entry or NULL if none is set.
  139.  */
  140.  
  141. extern Widget XawComplexMenuGetActiveEntry(
  142. #if NeedFunctionPrototypes
  143.     Widget        /* w */
  144. #endif
  145. );
  146.  
  147. /*    Function Name: XawComplexMenuClearActiveEntry
  148.  *    Description: Unsets the currently active (set) entry.
  149.  *    Arguments: w - the smw widget.
  150.  *    Returns: none.
  151.  */
  152.  
  153. extern void XawComplexMenuClearActiveEntry(
  154. #if NeedFunctionPrototypes
  155.     Widget        /* w */
  156. #endif
  157. );
  158.  
  159. _XFUNCPROTOEND
  160.  
  161. #endif /* _ComplexMenu_h */
  162.